package org.verlet.dto;

import org.verlet.entitry.SuccessKilled;
import org.verlet.enums.SeckillStatEnum;

public class SeckillExecution {
    private long secillId;
    //秒杀执行的结果
    private int state;
    //状态表示
    private String stateInfo;
    //秒杀成功对象
    private SuccessKilled successKilled;

    public SeckillExecution(long secillId, SeckillStatEnum statEnum) {
        this.secillId = secillId;
        this.state = statEnum.getState();
        this.stateInfo = statEnum.getStateInfo();
    }

    public SeckillExecution(long secillId, SeckillStatEnum statEnum, SuccessKilled successKilled) {
        this.secillId = secillId;
        this.state = statEnum.getState();
        this.stateInfo = statEnum.getStateInfo();
        this.successKilled = successKilled;
    }

    public long getSecillId() {
        return secillId;
    }

    public void setSecillId(long secillId) {
        this.secillId = secillId;
    }

    public int getState() {
        return state;
    }

    public void setState(int state) {
        this.state = state;
    }

    public String getStateInfo() {
        return stateInfo;
    }

    public void setStateInfo(String stateInfo) {
        this.stateInfo = stateInfo;
    }

    public SuccessKilled getSuccessKilled() {
        return successKilled;
    }

    public void setSuccessKilled(SuccessKilled successKilled) {
        this.successKilled = successKilled;
    }
}
